import java.util.Scanner;

public class TestDemo {

    public static void main(String[] args) {

    }

    public static boolean check(char c) {
        if ((c <= 'z' && c >= 'a') || (c >= 0 && c <=9)){
            return false;
        } else {
            return true;
        }
    }
    public static void main5(String[] args) {
        Scanner scan = new Scanner(System.in);
        String s = scan.nextLine();
//        String s = "a man , A plan , a canal , : Panama";
        s = s.toLowerCase();

        char[] ch = s.toCharArray();
        int i = 0;
        int j = s.length() - 1;

        while(i <= j) {
            while (check(s.charAt(i))) {
                i++;
            }
            while (check(s.charAt(j))) {
                j--;
            }
            if (!(s.charAt(i) == s.charAt(j))) {
                System.out.println("false");
                break;
            }
            i++;
            j--;
        }
        if (i > j || i == j) {
            System.out.println(true);
        }

    }

    public static void main4(String[] args) {
        Scanner scan = new Scanner(System.in);
        while(scan.hasNextLine()) {
            String s= scan.nextLine();
            int lastBlank = s.lastIndexOf(' ');
            String sub = s.substring(lastBlank + 1);
            System.out.println(sub);
        }
    }

    public static void main3(String[] args) {
        Scanner scan = new Scanner(System.in);
        while(scan.hasNextLine()) {
            String s= scan.nextLine();
            String[] str = s.split(" ");
            int c = 0;
            for (int i = 0; i < s.length(); i++) {
                if (s.charAt(i) == ' ') {
                    c++;
                }
            }
            System.out.println(str[c].length());
        }
    }

    public static void main2(String[] args) {
        String str = "mattylyhmatty";
        int[] c = new int[26];
        for (int i = 0; i < str.length(); i++) {
            c[str.charAt(i)-97]++;
        }
        for (int i = 0; i < str.length(); i++) {
            if (c[i] == 1) {
                char ch = (char) i;
                System.out.println(ch);
                break;
            }
        }
    }
    public static void main1(String[] args) {
//        char[] ch = {'a','b','c'};
//        String str = new String(ch);
//        str.intern();
//        String st = "abc";
//        System.out.println(str == st);


//        String Add = "2020 04 01 08";
//        String[] s1 = Add.split(" ",3);
//        for(String s:s1) {
//            System.out.println(s);
//        }

//        String[] s = "Matty lyh".split(" ");
//        System.out.println(s[0] + ' '+ s[1]);

//        String name = "Mattylyh";
//        System.out.println(name.replaceAll("t", "*"));
//        System.out.println(name.replaceFirst("t","*"));

//        String str = String.format("%d\\%d\\%d",1,2,3);
//        System.out.println(str);

//        String name = "Mattylyh";
//        char[] ch = name.toCharArray();
//        String nuh = new String(ch);
//        String Nuh = ch.toString();
//        System.out.println(name);
//        System.out.println(nuh);
//        System.out.println(Nuh);

//        String name = "Mattylyh";
//        System.out.println(name.toUpperCase());
//        System.out.println(name.toLowerCase());

//        String s0 = String.valueOf(829);
//        String s1 = String.valueOf(false);
//        String s2 = String.valueOf(new Man(20, "Matty"));  //重写toString后输出内容不一样
//        System.out.println(s0);
//        System.out.println(s1);
//        System.out.println(s2);


//        String name = "Mattylyh";
//        System.out.println(name.lastIndexOf("tty"));
//        System.out.println(name.lastIndexOf('y',7));
//        System.out.println(name.lastIndexOf('y'));
//        System.out.println(name.indexOf("lyh"));
//        System.out.println(name.indexOf('y',2));
//        System.out.println(name.indexOf('l'));
//        System.out.println(name.charAt(3));
    }
}

class Man {
    int age;
    String name;

    public Man(int age, String name) {
        this.age = age;
        this.name = name;
    }

    @Override
    public String toString() {
        return "Man{" +
                "age=" + age +
                ", name='" + name + '\'' +
                '}';
    }
}
